﻿using System;
using System.Diagnostics;

namespace CodeFirst.Test
{
    static class Utility
    {
        public static float TimeCost(this Stopwatch sw, Action action)
        {
            sw.Restart();
            action();
            return sw.ElapsedMilliseconds / 1000.0f;
        }
    }
}
